Integrand size = 13, antiderivative size = 44 \[ \int \frac {\cos ^4(x)}{a+a \csc (x)} \, dx=-\frac {x}{8 a}-\frac {\cos ^3(x)}{3 a}-\frac {\cos (x) \sin (x)}{8 a}+\frac {\cos ^3(x) \sin (x)}{4 a} \]
Time = 0.19 (sec) , antiderivative size = 40, normalized size of antiderivative = 0.91 \[ \int \frac {\cos ^4(x)}{a+a \csc (x)} \, dx=-\frac {x}{8 a}-\frac {\cos (x)}{4 a}-\frac {\cos (3 x)}{12 a}+\frac {\sin (4 x)}{32 a} \]
Time = 0.43 (sec) , antiderivative size = 46, normalized size of antiderivative = 1.05, number of steps used = 12, number of rules used = 11, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.846, Rules used = {3042, 4360, 3042, 3318, 3042, 3045, 15, 3048, 3042, 3115, 24}
Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.
\(\displaystyle \int \frac {\cos ^4(x)}{a \csc (x)+a} \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \frac {\cos (x)^4}{a \csc (x)+a}dx\) |
\(\Big \downarrow \) 4360 |
\(\displaystyle \int \frac {\sin (x) \cos ^4(x)}{a \sin (x)+a}dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \frac {\sin (x) \cos (x)^4}{a \sin (x)+a}dx\) |
\(\Big \downarrow \) 3318 |
\(\displaystyle \frac {\int \cos ^2(x) \sin (x)dx}{a}-\frac {\int \cos ^2(x) \sin ^2(x)dx}{a}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {\int \cos (x)^2 \sin (x)dx}{a}-\frac {\int \cos (x)^2 \sin (x)^2dx}{a}\) |
\(\Big \downarrow \) 3045 |
\(\displaystyle -\frac {\int \cos ^2(x)d\cos (x)}{a}-\frac {\int \cos (x)^2 \sin (x)^2dx}{a}\) |
\(\Big \downarrow \) 15 |
\(\displaystyle -\frac {\int \cos (x)^2 \sin (x)^2dx}{a}-\frac {\cos ^3(x)}{3 a}\) |
\(\Big \downarrow \) 3048 |
\(\displaystyle -\frac {\frac {1}{4} \int \cos ^2(x)dx-\frac {1}{4} \sin (x) \cos ^3(x)}{a}-\frac {\cos ^3(x)}{3 a}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle -\frac {\frac {1}{4} \int \sin \left (x+\frac {\pi }{2}\right )^2dx-\frac {1}{4} \sin (x) \cos ^3(x)}{a}-\frac {\cos ^3(x)}{3 a}\) |
\(\Big \downarrow \) 3115 |
\(\displaystyle -\frac {\frac {1}{4} \left (\frac {\int 1dx}{2}+\frac {1}{2} \sin (x) \cos (x)\right )-\frac {1}{4} \sin (x) \cos ^3(x)}{a}-\frac {\cos ^3(x)}{3 a}\) |
\(\Big \downarrow \) 24 |
\(\displaystyle -\frac {\cos ^3(x)}{3 a}-\frac {\frac {1}{4} \left (\frac {x}{2}+\frac {1}{2} \sin (x) \cos (x)\right )-\frac {1}{4} \sin (x) \cos ^3(x)}{a}\) |
3.1.1.3.1 Defintions of rubi rules used
Int[(a_.)*(x_)^(m_.), x_Symbol] :> Simp[a*(x^(m + 1)/(m + 1)), x] /; FreeQ[ {a, m}, x] && NeQ[m, -1]
Int[(cos[(e_.) + (f_.)*(x_)]*(a_.))^(m_.)*sin[(e_.) + (f_.)*(x_)]^(n_.), x_ Symbol] :> Simp[-(a*f)^(-1) Subst[Int[x^m*(1 - x^2/a^2)^((n - 1)/2), x], x, a*Cos[e + f*x]], x] /; FreeQ[{a, e, f, m}, x] && IntegerQ[(n - 1)/2] && !(IntegerQ[(m - 1)/2] && GtQ[m, 0] && LeQ[m, n])
Int[(cos[(e_.) + (f_.)*(x_)]*(b_.))^(n_)*((a_.)*sin[(e_.) + (f_.)*(x_)])^(m _), x_Symbol] :> Simp[(-a)*(b*Cos[e + f*x])^(n + 1)*((a*Sin[e + f*x])^(m - 1)/(b*f*(m + n))), x] + Simp[a^2*((m - 1)/(m + n)) Int[(b*Cos[e + f*x])^n *(a*Sin[e + f*x])^(m - 2), x], x] /; FreeQ[{a, b, e, f, n}, x] && GtQ[m, 1] && NeQ[m + n, 0] && IntegersQ[2*m, 2*n]
Int[((b_.)*sin[(c_.) + (d_.)*(x_)])^(n_), x_Symbol] :> Simp[(-b)*Cos[c + d* x]*((b*Sin[c + d*x])^(n - 1)/(d*n)), x] + Simp[b^2*((n - 1)/n) Int[(b*Sin [c + d*x])^(n - 2), x], x] /; FreeQ[{b, c, d}, x] && GtQ[n, 1] && IntegerQ[ 2*n]
Int[((cos[(e_.) + (f_.)*(x_)]*(g_.))^(p_)*((d_.)*sin[(e_.) + (f_.)*(x_)])^( n_.))/((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)]), x_Symbol] :> Simp[g^2/a Int [(g*Cos[e + f*x])^(p - 2)*(d*Sin[e + f*x])^n, x], x] - Simp[g^2/(b*d) Int [(g*Cos[e + f*x])^(p - 2)*(d*Sin[e + f*x])^(n + 1), x], x] /; FreeQ[{a, b, d, e, f, g, n, p}, x] && EqQ[a^2 - b^2, 0]
Int[(cos[(e_.) + (f_.)*(x_)]*(g_.))^(p_.)*(csc[(e_.) + (f_.)*(x_)]*(b_.) + (a_))^(m_.), x_Symbol] :> Int[(g*Cos[e + f*x])^p*((b + a*Sin[e + f*x])^m/Si n[e + f*x]^m), x] /; FreeQ[{a, b, e, f, g, p}, x] && IntegerQ[m]
Time = 0.38 (sec) , antiderivative size = 27, normalized size of antiderivative = 0.61
method | result | size |
parallelrisch | \(\frac {-12 x -32+3 \sin \left (4 x \right )-8 \cos \left (3 x \right )-24 \cos \left (x \right )}{96 a}\) | \(27\) |
risch | \(-\frac {x}{8 a}-\frac {\cos \left (x \right )}{4 a}+\frac {\sin \left (4 x \right )}{32 a}-\frac {\cos \left (3 x \right )}{12 a}\) | \(33\) |
default | \(\frac {\frac {4 \left (-\frac {\tan \left (\frac {x}{2}\right )^{7}}{16}-\frac {\tan \left (\frac {x}{2}\right )^{6}}{2}+\frac {7 \tan \left (\frac {x}{2}\right )^{5}}{16}-\frac {\tan \left (\frac {x}{2}\right )^{4}}{2}-\frac {7 \tan \left (\frac {x}{2}\right )^{3}}{16}-\frac {\tan \left (\frac {x}{2}\right )^{2}}{6}+\frac {\tan \left (\frac {x}{2}\right )}{16}-\frac {1}{6}\right )}{\left (1+\tan \left (\frac {x}{2}\right )^{2}\right )^{4}}-\frac {\arctan \left (\tan \left (\frac {x}{2}\right )\right )}{4}}{a}\) | \(81\) |
norman | \(\frac {-\frac {x}{8 a}-\frac {2}{3 a}-\frac {x \tan \left (\frac {x}{2}\right )}{8 a}-\frac {x \tan \left (\frac {x}{2}\right )^{2}}{2 a}-\frac {x \tan \left (\frac {x}{2}\right )^{3}}{2 a}-\frac {3 x \tan \left (\frac {x}{2}\right )^{4}}{4 a}-\frac {3 x \tan \left (\frac {x}{2}\right )^{5}}{4 a}-\frac {x \tan \left (\frac {x}{2}\right )^{6}}{2 a}-\frac {x \tan \left (\frac {x}{2}\right )^{7}}{2 a}-\frac {x \tan \left (\frac {x}{2}\right )^{8}}{8 a}-\frac {x \tan \left (\frac {x}{2}\right )^{9}}{8 a}-\frac {\tan \left (\frac {x}{2}\right )^{8}}{4 a}-\frac {15 \tan \left (\frac {x}{2}\right )^{4}}{4 a}-\frac {5 \tan \left (\frac {x}{2}\right )}{12 a}-\frac {9 \tan \left (\frac {x}{2}\right )^{7}}{4 a}-\frac {\tan \left (\frac {x}{2}\right )^{6}}{4 a}-\frac {\tan \left (\frac {x}{2}\right )^{5}}{4 a}-\frac {29 \tan \left (\frac {x}{2}\right )^{3}}{12 a}-\frac {5 \tan \left (\frac {x}{2}\right )^{2}}{12 a}}{\left (1+\tan \left (\frac {x}{2}\right )^{2}\right )^{4} \left (\tan \left (\frac {x}{2}\right )+1\right )}\) | \(224\) |
Time = 0.24 (sec) , antiderivative size = 30, normalized size of antiderivative = 0.68 \[ \int \frac {\cos ^4(x)}{a+a \csc (x)} \, dx=-\frac {8 \, \cos \left (x\right )^{3} - 3 \, {\left (2 \, \cos \left (x\right )^{3} - \cos \left (x\right )\right )} \sin \left (x\right ) + 3 \, x}{24 \, a} \]
\[ \int \frac {\cos ^4(x)}{a+a \csc (x)} \, dx=\frac {\int \frac {\cos ^{4}{\left (x \right )}}{\csc {\left (x \right )} + 1}\, dx}{a} \]
Leaf count of result is larger than twice the leaf count of optimal. 157 vs. \(2 (36) = 72\).
Time = 0.31 (sec) , antiderivative size = 157, normalized size of antiderivative = 3.57 \[ \int \frac {\cos ^4(x)}{a+a \csc (x)} \, dx=\frac {\frac {3 \, \sin \left (x\right )}{\cos \left (x\right ) + 1} - \frac {8 \, \sin \left (x\right )^{2}}{{\left (\cos \left (x\right ) + 1\right )}^{2}} - \frac {21 \, \sin \left (x\right )^{3}}{{\left (\cos \left (x\right ) + 1\right )}^{3}} - \frac {24 \, \sin \left (x\right )^{4}}{{\left (\cos \left (x\right ) + 1\right )}^{4}} + \frac {21 \, \sin \left (x\right )^{5}}{{\left (\cos \left (x\right ) + 1\right )}^{5}} - \frac {24 \, \sin \left (x\right )^{6}}{{\left (\cos \left (x\right ) + 1\right )}^{6}} - \frac {3 \, \sin \left (x\right )^{7}}{{\left (\cos \left (x\right ) + 1\right )}^{7}} - 8}{12 \, {\left (a + \frac {4 \, a \sin \left (x\right )^{2}}{{\left (\cos \left (x\right ) + 1\right )}^{2}} + \frac {6 \, a \sin \left (x\right )^{4}}{{\left (\cos \left (x\right ) + 1\right )}^{4}} + \frac {4 \, a \sin \left (x\right )^{6}}{{\left (\cos \left (x\right ) + 1\right )}^{6}} + \frac {a \sin \left (x\right )^{8}}{{\left (\cos \left (x\right ) + 1\right )}^{8}}\right )}} - \frac {\arctan \left (\frac {\sin \left (x\right )}{\cos \left (x\right ) + 1}\right )}{4 \, a} \]
1/12*(3*sin(x)/(cos(x) + 1) - 8*sin(x)^2/(cos(x) + 1)^2 - 21*sin(x)^3/(cos (x) + 1)^3 - 24*sin(x)^4/(cos(x) + 1)^4 + 21*sin(x)^5/(cos(x) + 1)^5 - 24* sin(x)^6/(cos(x) + 1)^6 - 3*sin(x)^7/(cos(x) + 1)^7 - 8)/(a + 4*a*sin(x)^2 /(cos(x) + 1)^2 + 6*a*sin(x)^4/(cos(x) + 1)^4 + 4*a*sin(x)^6/(cos(x) + 1)^ 6 + a*sin(x)^8/(cos(x) + 1)^8) - 1/4*arctan(sin(x)/(cos(x) + 1))/a
Leaf count of result is larger than twice the leaf count of optimal. 78 vs. \(2 (36) = 72\).
Time = 0.26 (sec) , antiderivative size = 78, normalized size of antiderivative = 1.77 \[ \int \frac {\cos ^4(x)}{a+a \csc (x)} \, dx=-\frac {x}{8 \, a} - \frac {3 \, \tan \left (\frac {1}{2} \, x\right )^{7} + 24 \, \tan \left (\frac {1}{2} \, x\right )^{6} - 21 \, \tan \left (\frac {1}{2} \, x\right )^{5} + 24 \, \tan \left (\frac {1}{2} \, x\right )^{4} + 21 \, \tan \left (\frac {1}{2} \, x\right )^{3} + 8 \, \tan \left (\frac {1}{2} \, x\right )^{2} - 3 \, \tan \left (\frac {1}{2} \, x\right ) + 8}{12 \, {\left (\tan \left (\frac {1}{2} \, x\right )^{2} + 1\right )}^{4} a} \]
-1/8*x/a - 1/12*(3*tan(1/2*x)^7 + 24*tan(1/2*x)^6 - 21*tan(1/2*x)^5 + 24*t an(1/2*x)^4 + 21*tan(1/2*x)^3 + 8*tan(1/2*x)^2 - 3*tan(1/2*x) + 8)/((tan(1 /2*x)^2 + 1)^4*a)
Time = 19.16 (sec) , antiderivative size = 25, normalized size of antiderivative = 0.57 \[ \int \frac {\cos ^4(x)}{a+a \csc (x)} \, dx=-\frac {3\,x+2\,\cos \left (3\,x\right )-\frac {3\,\sin \left (4\,x\right )}{4}+6\,\cos \left (x\right )}{24\,a} \]